package com.zxbit.flash.bean;

import android.os.Parcel;
import android.os.Parcelable;

import java.util.ArrayList;

public class ProductListData implements Parcelable {
    private String pRange;
    private ArrayList<ProductItemData> pList;

    public ProductListData() {

    }

    protected ProductListData(Parcel in) {
        pRange = in.readString();
        pList = in.createTypedArrayList(ProductItemData.CREATOR);
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeString(pRange);
        dest.writeTypedList(pList);
    }

    @Override
    public int describeContents() {
        return 0;
    }

    public static final Creator<ProductListData> CREATOR = new Creator<ProductListData>() {
        @Override
        public ProductListData createFromParcel(Parcel in) {
            return new ProductListData(in);
        }

        @Override
        public ProductListData[] newArray(int size) {
            return new ProductListData[size];
        }
    };

    public String getpRange() {
        return pRange;
    }

    public void setpRange(String pRange) {
        this.pRange = pRange;
    }

    public ArrayList<ProductItemData> getpList() {
        return pList;
    }

    public void setpList(ArrayList<ProductItemData> pList) {
        this.pList = pList;
    }
}
